// markdown-it plugin for generating line numbers.
// It depends on preWrapper plugin.


const lineNumbers = require("./_lineNumbers.js")
module.exports = md => {
    const fence = md.renderer.rules.fence
    md.renderer.rules.fence =  (...args)=>{
        const rawCode = fence(...args)
        return lineNumbers(rawCode)
    }
}
